package com.justgame.project.service.system.feign;

import com.justgame.project.cloud.common.constant.AppConstant;
import com.justgame.project.service.system.feign.fallback.SysStationOrderClientFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * SysStationOrder 微服务接口
 * @author ZhouWeiBo
 * @create 2022/4/20
 */
@FeignClient(value = AppConstant.SYSTEM,fallback = SysStationOrderClientFallback.class)
public interface ISysStationOrderClient {
    String API_PREFIX = "/feign/sys_station_order";

    String SELECT_HAS_BOUGHT_GAME = API_PREFIX + "/has-bought-game";

    /**
     * 查询某用户是否已购买某游戏
     * @return
     */
    @GetMapping(SELECT_HAS_BOUGHT_GAME)
    Boolean hasBought(@RequestParam("userId") Long userId,@RequestParam("gameId") Long gameId);

}
